package com.oa.admin.entity;

import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.enums.IdType;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

@ApiModel("请假申请")
@TableName("admin_leave_apply")
@Data
public class LeaveApply extends Model<LeaveApply> {

    @ApiModelProperty("id")
    @TableId(value = "id", type = IdType.UUID)
    private String id;

    @ApiModelProperty("用户ID")
    private String userId;

    @ApiModelProperty("请假类别")
    private Integer leaveType;

    @ApiModelProperty("请假开始时间")
    private Date leaveStartTime;

    @ApiModelProperty("请假结束时间")
    private Date leaveEndTime;

    @ApiModelProperty("请假原因")
    private String leaveReason;

    @ApiModelProperty("请假文件名称")
    private String leaveFileName;

    @ApiModelProperty("请假附件地址")
    private String leaveFileAddress;

    @ApiModelProperty("文件大小")
    private String leaveFileSize;

    @ApiModelProperty("状态（1-审核中 2-通过）")
    private Integer status;

    @ApiModelProperty("创建时间")
    private Date createTime;

    @Override
    protected Serializable pkVal() {
        return this.id;
    }
}
